<?php

/**
 * Created by PhpStorm
 * User: 林振宇
 * Date: 2020/8/12
 * Time: 17:40
 */

namespace app\api\model;

use think\Model;
use think\Request;

class Product extends Model
{

    public function getImageAttr($value)
    {
        $domain = Request::instance()->domain();
        return $domain . $value;
    }

    public function VesselType()
    {
        return $this->belongsTo('VesselType', 'vessel_type_id', 'id');
    }

}
